#pragma once
#include <cstdio>

class GrayReader
{
private:
	static const int BUFSIZE = 1000;
	FILE *datafile, *metafile;
	char buf[BUFSIZE];
	bool parsed;
public:
	int width, height;
	int curRecId, curRecClocks;
	unsigned char *tmpFrameBuf;

public:
	GrayReader(char datafilename[], char metafilename[]);
	~GrayReader(void);
	bool getNextRec(void);
	bool getNextFrame(unsigned char *sptr);
};

